<?php
    $currentPage = $this->currentPage;
    $id = $this->id;
    $columns = 2;
    $error =$this->error;
?>
 <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
  <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>

  <script  src="<?php  echo JS_PATH.'/jquery/validate/jquery.validate.pack.js';?>"></script>
<script>
     $(document).ready(function(){

    $("#commentForm").validate({
		rules: {
                        passold: {
				required: true,
				minlength: 5
			},
			passnew: {
				required: true,
				minlength: 5
			},
			pass_confirm: {
				required: true,
				minlength: 5,
				equalTo: "#passnew"
			}
		},
		messages: {
                        passold: {
				required: "Please provide a password",
				minlength: "Your password must be at least 5 characters long"
			},
			passnew: {
				required: "Please provide a password",
				minlength: "Your password must be at least 5 characters long"
			},
			pass_confirm: {
				required: "Please provide a password",
				minlength: "Your password must be at least 5 characters long",
				equalTo: "Please enter the same password as above"
			}
		}
	});

  });
</script>


            <div class="browsetitle">
                Change Password
                <hr style="height:1px;">
            </div>
             <?php
                if($error) {
            ?>
                <div class="errormessage"><?=$error?></div>
            <?php
                }
            ?>
        <form action="" method="post" name="commentForm" id="commentForm">
        <table>
            <tbody>
                <tr>
                    <td> Old Password</td>
                    <td><input type="password" name="passold" id="passold" value="" class="uniform"/>
                        
                    </td>
                </tr>
                <tr>
                    <td>New Password </td>
                    <td><input type="password" name="passnew" value="" id="passnew"  class="uniform"/></td>
                </tr>
                 <tr>
                    <td>Confirm Password </td>
                    <td><input type="password" name="pass_confirm" value="" id="pass_confirm" class="uniform"/></td>
                </tr>
                <tr>
                    <td colspan="2"><input type="submit" value="Submit"  class="uniform"/></td>
                </tr>
            </tbody>
        </table>
        </form>
        </td>